<template>
  <div class="box1">
    <div class="box">
      <div>
        <el-button type="primary" class="btn" @click="switch1">登录</el-button>
        <el-button type="success" class="btn" @click="switch2">注册</el-button>
      </div>
      <router-view></router-view>
    </div>
  </div>
</template>

<script setup lang="ts">
import { useRouter } from "vue-router";

const router = useRouter();
function switch1() {
  router.push("/login/log");
}
function switch2() {
  router.push("/login/registered");
}
</script>
<style scoped lang="scss">
.box1 {
  width: 100vw;
  height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  background-color: rgba($color: #626aef, $alpha: 0.6);
}
.btn {
  border-radius: 0;
  margin: 0 !important;
}
.box {
  margin-bottom: 2.5rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}
</style>
